package com.youme.section.shop

import android.os.Bundle
import android.view.WindowManager
import androidx.appcompat.app.AppCompatActivity
import com.hyphenate.easeim.R
import com.youme.model.FoodAdd
import kotlinx.android.synthetic.main.activity_shop_details.*

class ShopDetailsActivity : AppCompatActivity(), FragmentShowListenerr, AddCaiListenerr {


    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        window.addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS)
        setContentView(R.layout.activity_shop_details)
        layout_main.fragmentIsShow(this)
        layout_price.setActivity(this)
    }

    override fun fragmentShow() {
        layout_price.setCarListener(layout_main.getCarListener())
        layout_main.setAddListener(this)
    }

    override fun addCai(food: FoodAdd?) {
        food?.let { layout_price.addCai(it) }
    }
}